<?php
/**
 * Created by PhpStorm.
 * User: u
 * Date: 2019/1/7
 * Time: 18:16
 */

namespace common\sources\write\regcode;

use Yii;

class RegCodeAccess implements IRegCodeAccess
{
    public function createRegCode($data)
    {
        return Yii::$app->db->createCommand()->insert('reg_code', [
            'config_key' => $data['reg_code_value'],
            'config_value' => $data['config_value'],
            'create_time' => time()
        ])->execute();
    }
}